<?php
cmspad_import('widget.Widget');
class TextAreaWidget extends Widget{
	
	public $cols;
	
	public $rows;
	
	public function __toString(){
		$html = '<TEXTAREA';
		if($this->id){
			$html .= ' id="'.$this->id.'"';
		}
		if($this->name){
			$html .= ' name="'.$this->name.'"';
		}
		if($this->class){
			$html .= ' class="'.$this->class.'"';
		}
		if($this->style){
			$html .= ' style="'.$this->style.'"';
		}
		if($this->cols){
			$html .= ' cols="'.$this->cols.'"';
		}
		if($this->rows){
			$html .= ' rows="'.$this->rows.'"';
		}
		$html .= '>';
		if($this->value){
			$html .= $this->value;
		}
		$html .= '</TEXTAREA>';
		return $html;
	}
}
?>